Skip to content

Force landscape orientation in player - #113

Merged
ProdigyV21 merged 1 commit into
ProdigyV21:mainfrom
Himanth-reddy:fix/player-landscape-orientation
Apr 5, 2026
Merged

Force landscape orientation in player#113
ProdigyV21 merged 1 commit into
ProdigyV21:mainfrom
Himanth-reddy:fix/player-landscape-orientation

Conversation

@Himanth-reddy

Copy link
Copy Markdown
Collaborator

What Changed

This updates the player so playback opens in landscape mode instead of portrait on mobile/tablet devices.

The player now:

  • switches the host activity to SCREEN_ORIENTATION_SENSOR_LANDSCAPE while the player screen is visible
  • allows auto-rotation between the two landscape directions
  • restores the previous activity orientation when the player is closed

Why

Movies and TV shows are primarily consumed in landscape, but the app was opening the player in portrait when the device itself was upright. That made the initial playback experience feel wrong and inconsistent.

Root Cause

MainActivity uses sensor-based orientation on phones and tablets, so when the player opened, it inherited the device's current portrait orientation instead of enforcing a playback-friendly landscape mode.

Impact

  • player opens in landscape for video playback
  • better viewing experience for movies and episodes
  • normal app orientation behavior resumes after exiting the player

Validation

  • built and verified with:
    • ./gradlew :app:compilePlayDebugKotlin :app:compileSideloadDebugKotlin

@ProdigyV21
ProdigyV21 merged commit e5486a1 into ProdigyV21:main Apr 5, 2026
2 checks passed
@Himanth-reddy
Himanth-reddy deleted the fix/player-landscape-orientation branch April 12, 2026 17:17
@Himanth-reddy Himanth-reddy added gssoc-approved level:beginner Beginner level task quality:clean Clean code implementation type:bug Bug fix gssoc:approved GSSoC approved contribution and removed gssoc:approved labels Jul 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gssoc:approved GSSoC approved contribution level:beginner Beginner level task quality:clean Clean code implementation type:bug Bug fix

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants